Implement scrolling of TTY menus when the screen is too short.
authorEli Zaretskii <eliz@gnu.org>
Mon, 14 Oct 2013 15:37:12 +0000 (18:37 +0300)
committerEli Zaretskii <eliz@gnu.org>
Mon, 14 Oct 2013 15:37:12 +0000 (18:37 +0300)
commitf1c46ddc2b673f1d3a53c638c9d8c81ea9ac3db6
tree6797b34c7c5f7fa9b3e37f6a1d86818127fbfdc9
parent2b7e80617b65bbfaa6737e0ca8fde9753d6b72b7
Implement scrolling of TTY menus when the screen is too short.

 src/term.c (tty_menu_display): Accept an additional argument, the
 menu item from which to start displaying the menu.  Account for
 the value of Y when limiting the menu to the number of available
 screen lines.
 (mi_result): New enumeration.
 (read_menu_input): Return enumerated value.  When the y coordinate
 hits min_y or max_y, return scroll indication instead of wrapping
 around the menu.
 (tty_menu_activate): Handle the scrolling indications from
 read_menu_input.  Compute the first menu item to display and pass
 it to tty_menu_display.

 lisp/menu-bar.el (tty-menu-navigation-map): Bind shifted mouse clicks
 to commands that scroll the menu.
lisp/ChangeLog
lisp/menu-bar.el
src/ChangeLog
src/term.c